package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.RecompenseMapper;
import com.ruoyi.system.domain.Recompense;
import com.ruoyi.system.service.IRecompenseService;
import com.ruoyi.common.core.text.Convert;

/**
 * 慢病报销Service业务层处理
 * 
 * @author moweiyu
 * @date 2021-05-21
 */
@Service
public class RecompenseServiceImpl implements IRecompenseService 
{
    @Autowired
    private RecompenseMapper recompenseMapper;

    /**
     * 查询慢病报销
     * 
     * @param medInfoId 慢病报销ID
     * @return 慢病报销
     */
    @Override
    public Recompense selectRecompenseById(Long medInfoId)
    {
        return recompenseMapper.selectRecompenseById(medInfoId);
    }

    /**
     * 查询慢病报销列表
     * 
     * @param recompense 慢病报销
     * @return 慢病报销
     */
    @Override
    public List<Recompense> selectRecompenseList(Recompense recompense)
    {
        return recompenseMapper.selectRecompenseList(recompense);
    }

    /**
     * 新增慢病报销
     * 
     * @param recompense 慢病报销
     * @return 结果
     */
    @Override
    public int insertRecompense(Recompense recompense)
    {
        return recompenseMapper.insertRecompense(recompense);
    }

    /**
     * 修改慢病报销
     * 
     * @param recompense 慢病报销
     * @return 结果
     */
    @Override
    public int updateRecompense(Recompense recompense)
    {
        return recompenseMapper.updateRecompense(recompense);
    }

    /**
     * 删除慢病报销对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteRecompenseByIds(String ids)
    {
        return recompenseMapper.deleteRecompenseByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除慢病报销信息
     * 
     * @param medInfoId 慢病报销ID
     * @return 结果
     */
    @Override
    public int deleteRecompenseById(Long medInfoId)
    {
        return recompenseMapper.deleteRecompenseById(medInfoId);
    }
}
